package com.haistand.module.common.controller;



import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.stereotype.Controller;
import org.springframework.web.context.request.RequestContextHolder;
import org.springframework.web.context.request.ServletRequestAttributes;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * @author :Anjero
 * @version :1.0
 * @Title :BaseAdminController.java
 * @Description:
 * @Datetime :2013-8-23
 * @Copyright :Copyright (c) 2012
 * @Company :Cheshell
 */
@Controller
public class BaseAdminController extends BaseController {






    public UserDetails adminUser() {
        UserDetails userDetails = (UserDetails) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
        return userDetails;
    }


}
